#！/usr/bin/bash
#安装xtrabackup
 yum install -y xtrabackup
#检查yum安装是否完成
if [ $? -eq 0 ]; then 
   echo "xtrabackup安装完成"
else
   echo "xtrabackup安装失败"
fi
yum localinstall -y *.rpm
#解压xtrabackup安装包
  tar xvzf xtrabackup.tar.gz
if [ $? -eq 0 ]; then
   echo "解压完成"
else
   echo "解压成功"
fi
#定义MySQL数据路径和备份路径
#MySQL_dir=/home/mysql/.ysql.1   #备份目录路径
#mysql 
 